﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/Site.Master" CodeBehind="Detail.aspx.vb" Inherits="Car.Detail" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
        DataKeyNames="ID" DataSourceID="CarDetailSqlDataSource">
        <Columns>
            <asp:BoundField DataField="Manufacturer" HeaderText="Manufacturer" 
                SortExpression="Manufacturer" />
            <asp:BoundField DataField="Model" HeaderText="Model" SortExpression="Model" />
            <asp:BoundField DataField="Website" HeaderText="Website" 
                SortExpression="Website" />
            <asp:BoundField DataField="Contact" HeaderText="Contact" 
                SortExpression="Contact" />
            <asp:BoundField DataField="PostCode" HeaderText="PostCode" 
                SortExpression="PostCode" />
            <asp:BoundField DataField="SafetyRating" HeaderText="SafetyRating" 
                SortExpression="SafetyRating" />
            <asp:ImageField DataAlternateTextField="Picture" DataImageUrlField="Picture" 
                HeaderText="Picture">
            </asp:ImageField>
        </Columns>
    </asp:GridView>
    <asp:SqlDataSource ID="CarDetailSqlDataSource" runat="server" 
        ConnectionString="<%$ ConnectionStrings:CarsConnectionString %>" 
        ProviderName="<%$ ConnectionStrings:CarsConnectionString.ProviderName %>" 
        SelectCommand="SELECT [ID], [Manufacturer], [Model], [Website], [Contact], [Picture], [PostCode], [SafetyRating] FROM [Car] WHERE ([ID] = ?)">
        <SelectParameters>
            <asp:QueryStringParameter Name="ID" QueryStringField="ID" Type="Int32" />
        </SelectParameters>
    </asp:SqlDataSource>
    <br />
    <br />
    <br />
    <br />
    <br />
</asp:Content>
